const SUBJECT = 'subject'

const getPermission = (targetPermission: string): boolean => {
    // 从localStorage获取权限数据，如果没有则返回false
    const permissions = JSON.parse(localStorage.getItem(SUBJECT) || '[]');
    // 使用some()方法检查数组中是否存在符合条件的项
    return permissions.some((item: any) => item == targetPermission);
  };
  export {getPermission};